﻿/******************************************************************************************************
Copyright (c) 2014 Steven Giacomelli (stevegiacomelli@gmail.com)

Permission is hereby granted, free of charge, to any person obtaining a copy of this
software and associated documentation files (the "Software"), to deal in the Software
without restriction, including without limitation the rights to use, copy, modify,
merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies
or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE
FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
******************************************************************************************************/

using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Reflection;

namespace SharpGeo
{
    /// <summary>
    /// A static class containing standard color definitions
    /// </summary>
    public static class StandardColors
    {
        /// <summary>
        /// AliceBlue
        /// </summary>
        public static readonly Color AliceBlue = new Color(0xFF, 0xF0, 0xFF, 0xF8);

        /// <summary>
        /// AntiqueWhite
        /// </summary>
        public static readonly Color AntiqueWhite = new Color(0xFF, 0xFA, 0xD7, 0xEB);

        /// <summary>
        /// Aqua
        /// </summary>
        public static readonly Color Aqua = new Color(0xFF, 0x0, 0xFF, 0xFF);

        /// <summary>
        /// Aquamarine
        /// </summary>
        public static readonly Color Aquamarine = new Color(0xFF, 0x7F, 0xD4, 0xFF);

        /// <summary>
        /// Azure
        /// </summary>
        public static readonly Color Azure = new Color(0xFF, 0xF0, 0xFF, 0xFF);

        /// <summary>
        /// Beige
        /// </summary>
        public static readonly Color Beige = new Color(0xFF, 0xF5, 0xDC, 0xF5);

        /// <summary>
        /// Bisque
        /// </summary>
        public static readonly Color Bisque = new Color(0xFF, 0xFF, 0xC4, 0xE4);

        /// <summary>
        /// Black
        /// </summary>
        public static readonly Color Black = new Color(0xFF, 0x0, 0x0, 0x0);

        /// <summary>
        /// BlanchedAlmond
        /// </summary>
        public static readonly Color BlanchedAlmond = new Color(0xFF, 0xFF, 0xCD, 0xEB);

        /// <summary>
        /// Blue
        /// </summary>
        public static readonly Color Blue = new Color(0xFF, 0x0, 0xFF, 0x0);

        /// <summary>
        /// BlueViolet
        /// </summary>
        public static readonly Color BlueViolet = new Color(0xFF, 0x8A, 0xE2, 0x2B);

        /// <summary>
        /// Brown
        /// </summary>
        public static readonly Color Brown = new Color(0xFF, 0xA5, 0x2A, 0x2A);

        /// <summary>
        /// BurlyWood
        /// </summary>
        public static readonly Color BurlyWood = new Color(0xFF, 0xDE, 0x87, 0xB8);

        /// <summary>
        /// CadetBlue
        /// </summary>
        public static readonly Color CadetBlue = new Color(0xFF, 0x5F, 0xA0, 0x9E);

        /// <summary>
        /// Chartreuse
        /// </summary>
        public static readonly Color Chartreuse = new Color(0xFF, 0x7F, 0x0, 0xFF);

        /// <summary>
        /// Chocolate
        /// </summary>
        public static readonly Color Chocolate = new Color(0xFF, 0xD2, 0x1E, 0x69);

        /// <summary>
        /// Coral
        /// </summary>
        public static readonly Color Coral = new Color(0xFF, 0xFF, 0x50, 0x7F);

        /// <summary>
        /// CornFlowerBlue
        /// </summary>
        public static readonly Color CornflowerBlue = new Color(0xFF, 0x64, 0xED, 0x95);

        /// <summary>
        /// CornSilk
        /// </summary>
        public static readonly Color CornSilk = new Color(0xFF, 0xFF, 0xDC, 0xF8);

        /// <summary>
        /// Crimson
        /// </summary>
        public static readonly Color Crimson = new Color(0xFF, 0xDC, 0x3C, 0x14);

        /// <summary>
        /// Cyan
        /// </summary>
        public static readonly Color Cyan = new Color(0xFF, 0x0, 0xFF, 0xFF);

        /// <summary>
        /// DarkBlue
        /// </summary>
        public static readonly Color DarkBlue = new Color(0xFF, 0x0, 0x8B, 0x0);

        /// <summary>
        /// DarkCyan
        /// </summary>
        public static readonly Color DarkCyan = new Color(0xFF, 0x0, 0x8B, 0x8B);

        /// <summary>
        /// DarkGoldenrod
        /// </summary>
        public static readonly Color DarkGoldenrod = new Color(0xFF, 0xB8, 0xB, 0x86);

        /// <summary>
        /// DarkGray
        /// </summary>
        public static readonly Color DarkGray = new Color(0xFF, 0xA9, 0xA9, 0xA9);

        /// <summary>
        /// DarkGreen
        /// </summary>
        public static readonly Color DarkGreen = new Color(0xFF, 0x0, 0x0, 0x64);

        /// <summary>
        /// DarkGrey
        /// </summary>
        public static readonly Color DarkGrey = new Color(0xFF, 0xA9, 0xA9, 0xA9);

        /// <summary>
        /// DarkKhaki
        /// </summary>
        public static readonly Color DarkKhaki = new Color(0xFF, 0xBD, 0x6B, 0xB7);

        /// <summary>
        /// DarkMagenta
        /// </summary>
        public static readonly Color DarkMagenta = new Color(0xFF, 0x8B, 0x8B, 0x0);

        /// <summary>
        /// DarkOliveGreen
        /// </summary>
        public static readonly Color DarkOliveGreen = new Color(0xFF, 0x55, 0x2F, 0x6B);

        /// <summary>
        /// DarkOrange
        /// </summary>
        public static readonly Color DarkOrange = new Color(0xFF, 0xFF, 0x0, 0x8C);

        /// <summary>
        /// DarkOrchid
        /// </summary>
        public static readonly Color DarkOrchid = new Color(0xFF, 0x99, 0xCC, 0x32);

        /// <summary>
        /// DarkRed
        /// </summary>
        public static readonly Color DarkRed = new Color(0xFF, 0x8B, 0x0, 0x0);

        /// <summary>
        /// DarkSalmon
        /// </summary>
        public static readonly Color DarkSalmon = new Color(0xFF, 0xE9, 0x7A, 0x96);

        /// <summary>
        /// DarkSeaGreen
        /// </summary>
        public static readonly Color DarkSeaGreen = new Color(0xFF, 0x8F, 0x8F, 0xBC);

        /// <summary>
        /// DarkSlateBlue
        /// </summary>
        public static readonly Color DarkSlateBlue = new Color(0xFF, 0x48, 0x8B, 0x3D);

        /// <summary>
        /// DarkSlateGray
        /// </summary>
        public static readonly Color DarkSlateGray = new Color(0xFF, 0x2F, 0x4F, 0x4F);

        /// <summary>
        /// DarkSlateGrey
        /// </summary>
        public static readonly Color DarkSlateGrey = new Color(0xFF, 0x2F, 0x4F, 0x4F);

        /// <summary>
        /// DarkTurquoise
        /// </summary>
        public static readonly Color DarkTurquoise = new Color(0xFF, 0x0, 0xD1, 0xCE);

        /// <summary>
        /// DarkViolet
        /// </summary>
        public static readonly Color DarkViolet = new Color(0xFF, 0x94, 0xD3, 0x0);

        /// <summary>
        /// DeepPink
        /// </summary>
        public static readonly Color DeepPink = new Color(0xFF, 0xFF, 0x93, 0x14);

        /// <summary>
        /// DeepSkyBlue
        /// </summary>
        public static readonly Color DeepSkyBlue = new Color(0xFF, 0x0, 0xFF, 0xBF);

        /// <summary>
        /// DimGray
        /// </summary>
        public static readonly Color DimGray = new Color(0xFF, 0x69, 0x69, 0x69);

        /// <summary>
        /// DimGrey
        /// </summary>
        public static readonly Color DimGrey = new Color(0xFF, 0x69, 0x69, 0x69);

        /// <summary>
        /// DodgerBlue
        /// </summary>
        public static readonly Color DodgerBlue = new Color(0xFF, 0x1E, 0xFF, 0x90);

        /// <summary>
        /// Firebrick
        /// </summary>
        public static readonly Color Firebrick = new Color(0xFF, 0xB2, 0x22, 0x22);

        /// <summary>
        /// FloralWhite
        /// </summary>
        public static readonly Color FloralWhite = new Color(0xFF, 0xFF, 0xF0, 0xFA);

        /// <summary>
        /// ForestGreen
        /// </summary>
        public static readonly Color ForestGreen = new Color(0xFF, 0x22, 0x22, 0x8B);

        /// <summary>
        /// Fuchsia
        /// </summary>
        public static readonly Color Fuchsia = new Color(0xFF, 0xFF, 0xFF, 0x0);

        /// <summary>
        /// Gainsboro
        /// </summary>
        public static readonly Color Gainsboro = new Color(0xFF, 0xDC, 0xDC, 0xDC);

        /// <summary>
        /// GhostWhite
        /// </summary>
        public static readonly Color GhostWhite = new Color(0xFF, 0xF8, 0xFF, 0xF8);

        /// <summary>
        /// Gold
        /// </summary>
        public static readonly Color Gold = new Color(0xFF, 0xFF, 0x0, 0xD7);

        /// <summary>
        /// Goldenrod
        /// </summary>
        public static readonly Color Goldenrod = new Color(0xFF, 0xDA, 0x20, 0xA5);

        /// <summary>
        /// Gray
        /// </summary>
        public static readonly Color Gray = new Color(0xFF, 0x80, 0x80, 0x80);

        /// <summary>
        /// Green
        /// </summary>
        public static readonly Color Green = new Color(0xFF, 0x0, 0x0, 0x80);

        /// <summary>
        /// GreenYellow
        /// </summary>
        public static readonly Color GreenYellow = new Color(0xFF, 0xAD, 0x2F, 0xFF);

        /// <summary>
        /// Grey
        /// </summary>
        public static readonly Color Grey = new Color(0xFF, 0x80, 0x80, 0x80);

        /// <summary>
        /// Honeydew
        /// </summary>
        public static readonly Color Honeydew = new Color(0xFF, 0xF0, 0xF0, 0xFF);

        /// <summary>
        /// HotPink
        /// </summary>
        public static readonly Color HotPink = new Color(0xFF, 0xFF, 0xB4, 0x69);

        /// <summary>
        /// IndianRed
        /// </summary>
        public static readonly Color IndianRed = new Color(0xFF, 0xCD, 0x5C, 0x5C);

        /// <summary>
        /// Indigo
        /// </summary>
        public static readonly Color Indigo = new Color(0xFF, 0x4B, 0x82, 0x0);

        /// <summary>
        /// Ivory
        /// </summary>
        public static readonly Color Ivory = new Color(0xFF, 0xFF, 0xF0, 0xFF);

        /// <summary>
        /// Khaki
        /// </summary>
        public static readonly Color Khaki = new Color(0xFF, 0xF0, 0x8C, 0xE6);

        /// <summary>
        /// Lavender
        /// </summary>
        public static readonly Color Lavender = new Color(0xFF, 0xE6, 0xFA, 0xE6);

        /// <summary>
        /// LavenderBlush
        /// </summary>
        public static readonly Color LavenderBlush = new Color(0xFF, 0xFF, 0xF5, 0xF0);

        /// <summary>
        /// LawnGreen
        /// </summary>
        public static readonly Color LawnGreen = new Color(0xFF, 0x7C, 0x0, 0xFC);

        /// <summary>
        /// LemonChiffon
        /// </summary>
        public static readonly Color LemonChiffon = new Color(0xFF, 0xFF, 0xCD, 0xFA);

        /// <summary>
        /// LightBlue
        /// </summary>
        public static readonly Color LightBlue = new Color(0xFF, 0xAD, 0xE6, 0xD8);

        /// <summary>
        /// LightCoral
        /// </summary>
        public static readonly Color LightCoral = new Color(0xFF, 0xF0, 0x80, 0x80);

        /// <summary>
        /// LightCyan
        /// </summary>
        public static readonly Color LightCyan = new Color(0xFF, 0xE0, 0xFF, 0xFF);

        /// <summary>
        /// LightGoldenrodYellow
        /// </summary>
        public static readonly Color LightGoldenrodYellow = new Color(0xFF, 0xFA, 0xD2, 0xFA);

        /// <summary>
        /// LightGray
        /// </summary>
        public static readonly Color LightGray = new Color(0xFF, 0xD3, 0xD3, 0xD3);

        /// <summary>
        /// LightGreen
        /// </summary>
        public static readonly Color LightGreen = new Color(0xFF, 0x90, 0x90, 0xEE);

        /// <summary>
        /// LightGrey
        /// </summary>
        public static readonly Color LightGrey = new Color(0xFF, 0xD3, 0xD3, 0xD3);

        /// <summary>
        /// LightPink
        /// </summary>
        public static readonly Color LightPink = new Color(0xFF, 0xFF, 0xC1, 0xB6);

        /// <summary>
        /// LightSalmon
        /// </summary>
        public static readonly Color LightSalmon = new Color(0xFF, 0xFF, 0x7A, 0xA0);

        /// <summary>
        /// LightSeaGreen
        /// </summary>
        public static readonly Color LightSeaGreen = new Color(0xFF, 0x20, 0xAA, 0xB2);

        /// <summary>
        /// LightSkyBlue
        /// </summary>
        public static readonly Color LightSkyBlue = new Color(0xFF, 0x87, 0xFA, 0xCE);

        /// <summary>
        /// LightSlateGray
        /// </summary>
        public static readonly Color LightSlateGray = new Color(0xFF, 0x77, 0x99, 0x88);

        /// <summary>
        /// LightSlateGrey
        /// </summary>
        public static readonly Color LightSlateGrey = new Color(0xFF, 0x77, 0x99, 0x88);

        /// <summary>
        /// LightSteelBlue
        /// </summary>
        public static readonly Color LightSteelBlue = new Color(0xFF, 0xB0, 0xDE, 0xC4);

        /// <summary>
        /// LightYellow
        /// </summary>
        public static readonly Color LightYellow = new Color(0xFF, 0xFF, 0xE0, 0xFF);

        /// <summary>
        /// Lime
        /// </summary>
        public static readonly Color Lime = new Color(0xFF, 0x0, 0x0, 0xFF);

        /// <summary>
        /// LimeGreen
        /// </summary>
        public static readonly Color LimeGreen = new Color(0xFF, 0x32, 0x32, 0xCD);

        /// <summary>
        /// Linen
        /// </summary>
        public static readonly Color Linen = new Color(0xFF, 0xFA, 0xE6, 0xF0);

        /// <summary>
        /// Magenta
        /// </summary>
        public static readonly Color Magenta = new Color(0xFF, 0xFF, 0xFF, 0x0);

        /// <summary>
        /// Maroon
        /// </summary>
        public static readonly Color Maroon = new Color(0xFF, 0x80, 0x0, 0x0);

        /// <summary>
        /// MediumAquamarine
        /// </summary>
        public static readonly Color MediumAquamarine = new Color(0xFF, 0x66, 0xAA, 0xCD);

        /// <summary>
        /// MediumBlue
        /// </summary>
        public static readonly Color MediumBlue = new Color(0xFF, 0x0, 0xCD, 0x0);

        /// <summary>
        /// MediumOrchid
        /// </summary>
        public static readonly Color MediumOrchid = new Color(0xFF, 0xBA, 0xD3, 0x55);

        /// <summary>
        /// MediumPurple
        /// </summary>
        public static readonly Color MediumPurple = new Color(0xFF, 0x93, 0xDB, 0x70);

        /// <summary>
        /// MediumSeaGreen
        /// </summary>
        public static readonly Color MediumSeaGreen = new Color(0xFF, 0x3C, 0x71, 0xB3);

        /// <summary>
        /// MediumSlateBlue
        /// </summary>
        public static readonly Color MediumSlateBlue = new Color(0xFF, 0x7B, 0xEE, 0x68);

        /// <summary>
        /// MediumSpringGreen
        /// </summary>
        public static readonly Color MediumSpringGreen = new Color(0xFF, 0x0, 0x9A, 0xFA);

        /// <summary>
        /// MediumTurquoise
        /// </summary>
        public static readonly Color MediumTurquoise = new Color(0xFF, 0x48, 0xCC, 0xD1);

        /// <summary>
        /// MediumVioletRed
        /// </summary>
        public static readonly Color MediumVioletRed = new Color(0xFF, 0xC7, 0x85, 0x15);

        /// <summary>
        /// MidnightBlue
        /// </summary>
        public static readonly Color MidnightBlue = new Color(0xFF, 0x19, 0x70, 0x19);

        /// <summary>
        /// MintCream
        /// </summary>
        public static readonly Color MintCream = new Color(0xFF, 0xF5, 0xFA, 0xFF);

        /// <summary>
        /// MistyRose
        /// </summary>
        public static readonly Color MistyRose = new Color(0xFF, 0xFF, 0xE1, 0xE4);

        /// <summary>
        /// Moccasin
        /// </summary>
        public static readonly Color Moccasin = new Color(0xFF, 0xFF, 0xB5, 0xE4);

        /// <summary>
        /// NavajoWhite
        /// </summary>
        public static readonly Color NavajoWhite = new Color(0xFF, 0xFF, 0xAD, 0xDE);

        /// <summary>
        /// Navy
        /// </summary>
        public static readonly Color Navy = new Color(0xFF, 0x0, 0x80, 0x0);

        /// <summary>
        /// OldLace
        /// </summary>
        public static readonly Color OldLace = new Color(0xFF, 0xFD, 0xE6, 0xF5);

        /// <summary>
        /// Olive
        /// </summary>
        public static readonly Color Olive = new Color(0xFF, 0x80, 0x0, 0x80);

        /// <summary>
        /// OliveDrab
        /// </summary>
        public static readonly Color OliveDrab = new Color(0xFF, 0x6B, 0x23, 0x8E);

        /// <summary>
        /// Orange
        /// </summary>
        public static readonly Color Orange = new Color(0xFF, 0xFF, 0x0, 0xA5);

        /// <summary>
        /// OrangeRed
        /// </summary>
        public static readonly Color OrangeRed = new Color(0xFF, 0xFF, 0x0, 0x45);

        /// <summary>
        /// Orchid
        /// </summary>
        public static readonly Color Orchid = new Color(0xFF, 0xDA, 0xD6, 0x70);

        /// <summary>
        /// PaleGoldenrod
        /// </summary>
        public static readonly Color PaleGoldenrod = new Color(0xFF, 0xEE, 0xAA, 0xE8);

        /// <summary>
        /// PaleGreen
        /// </summary>
        public static readonly Color PaleGreen = new Color(0xFF, 0x98, 0x98, 0xFB);

        /// <summary>
        /// PaleTurquoise
        /// </summary>
        public static readonly Color PaleTurquoise = new Color(0xFF, 0xAF, 0xEE, 0xEE);

        /// <summary>
        /// PaleVioletRed
        /// </summary>
        public static readonly Color PaleVioletRed = new Color(0xFF, 0xDB, 0x93, 0x70);

        /// <summary>
        /// PapayaWhip
        /// </summary>
        public static readonly Color PapayaWhip = new Color(0xFF, 0xFF, 0xD5, 0xEF);

        /// <summary>
        /// PeachPuff
        /// </summary>
        public static readonly Color PeachPuff = new Color(0xFF, 0xFF, 0xB9, 0xDA);

        /// <summary>
        /// Peru
        /// </summary>
        public static readonly Color Peru = new Color(0xFF, 0xCD, 0x3F, 0x85);

        /// <summary>
        /// Pink
        /// </summary>
        public static readonly Color Pink = new Color(0xFF, 0xFF, 0xCB, 0xC0);

        /// <summary>
        /// Plum
        /// </summary>
        public static readonly Color Plum = new Color(0xFF, 0xDD, 0xDD, 0xA0);

        /// <summary>
        /// PowderBlue
        /// </summary>
        public static readonly Color PowderBlue = new Color(0xFF, 0xB0, 0xE6, 0xE0);

        /// <summary>
        /// Purple
        /// </summary>
        public static readonly Color Purple = new Color(0xFF, 0x80, 0x80, 0x0);

        /// <summary>
        /// Red
        /// </summary>
        public static readonly Color Red = new Color(0xFF, 0xFF, 0x0, 0x0);

        /// <summary>
        /// RosyBrown
        /// </summary>
        public static readonly Color RosyBrown = new Color(0xFF, 0xBC, 0x8F, 0x8F);

        /// <summary>
        /// RoyalBlue
        /// </summary>
        public static readonly Color RoyalBlue = new Color(0xFF, 0x41, 0xE1, 0x69);

        /// <summary>
        /// SaddleBrown
        /// </summary>
        public static readonly Color SaddleBrown = new Color(0xFF, 0x8B, 0x13, 0x45);

        /// <summary>
        /// Salmon
        /// </summary>
        public static readonly Color Salmon = new Color(0xFF, 0xFA, 0x72, 0x80);

        /// <summary>
        /// SandyBrown
        /// </summary>
        public static readonly Color SandyBrown = new Color(0xFF, 0xF4, 0x60, 0xA4);

        /// <summary>
        /// SeaGreen
        /// </summary>
        public static readonly Color SeaGreen = new Color(0xFF, 0x2E, 0x57, 0x8B);

        /// <summary>
        /// Seashell
        /// </summary>
        public static readonly Color Seashell = new Color(0xFF, 0xFF, 0xEE, 0xF5);

        /// <summary>
        /// Sienna
        /// </summary>
        public static readonly Color Sienna = new Color(0xFF, 0xA0, 0x2D, 0x52);

        /// <summary>
        /// Silver
        /// </summary>
        public static readonly Color Silver = new Color(0xFF, 0xC0, 0xC0, 0xC0);

        /// <summary>
        /// SkyBlue
        /// </summary>
        public static readonly Color SkyBlue = new Color(0xFF, 0x87, 0xEB, 0xCE);

        /// <summary>
        /// SlateBlue
        /// </summary>
        public static readonly Color SlateBlue = new Color(0xFF, 0x6A, 0xCD, 0x5A);

        /// <summary>
        /// SlateGray
        /// </summary>
        public static readonly Color SlateGray = new Color(0xFF, 0x70, 0x90, 0x80);

        /// <summary>
        /// SlateGrey
        /// </summary>
        public static readonly Color SlateGrey = new Color(0xFF, 0x70, 0x90, 0x80);

        /// <summary>
        /// Snow
        /// </summary>
        public static readonly Color Snow = new Color(0xFF, 0xFF, 0xFA, 0xFA);

        /// <summary>
        /// SpringGreen
        /// </summary>
        public static readonly Color SpringGreen = new Color(0xFF, 0x0, 0x7F, 0xFF);

        /// <summary>
        /// SteelBlue
        /// </summary>
        public static readonly Color SteelBlue = new Color(0xFF, 0x46, 0xB4, 0x82);

        /// <summary>
        /// Tan
        /// </summary>
        public static readonly Color Tan = new Color(0xFF, 0xD2, 0x8C, 0xB4);

        /// <summary>
        /// Teal
        /// </summary>
        public static readonly Color Teal = new Color(0xFF, 0x0, 0x80, 0x80);

        /// <summary>
        /// Thistle
        /// </summary>
        public static readonly Color Thistle = new Color(0xFF, 0xD8, 0xD8, 0xBF);

        /// <summary>
        /// Tomato
        /// </summary>
        public static readonly Color Tomato = new Color(0xFF, 0xFF, 0x47, 0x63);

        /// <summary>
        /// Turquoise
        /// </summary>
        public static readonly Color Turquoise = new Color(0xFF, 0x40, 0xD0, 0xE0);

        /// <summary>
        /// Violet
        /// </summary>
        public static readonly Color Violet = new Color(0xFF, 0xEE, 0xEE, 0x82);

        /// <summary>
        /// Wheat
        /// </summary>
        public static readonly Color Wheat = new Color(0xFF, 0xF5, 0xB3, 0xDE);

        /// <summary>
        /// White
        /// </summary>
        public static readonly Color White = new Color(0xFF, 0xFF, 0xFF, 0xFF);

        /// <summary>
        /// WhiteSmoke
        /// </summary>
        public static readonly Color WhiteSmoke = new Color(0xFF, 0xF5, 0xF5, 0xF5);

        /// <summary>
        /// Yellow
        /// </summary>
        public static readonly Color Yellow = new Color(0xFF, 0xFF, 0x0, 0xFF);

        /// <summary>
        /// YellowGreen
        /// </summary>
        public static readonly Color YellowGreen = new Color(0xFF, 0x9A, 0x32, 0xCD);

        private static Dictionary<string, Color> _standardColors = null;

        /// <summary>
        /// Static factory method to return a color based on a recognized SVG color keyword
        /// </summary>
        /// <param name="name">A recognized SVG color keyword</param>
        /// <returns>A Color describing the recognized SVG color keyword</returns>
        public static Color GetStandardColor(string name)
        {
            if (string.IsNullOrWhiteSpace(name))
            {
                return StandardColors.White;
            }

            if (_standardColors == null)
            {
                LoadStandardColors();
            }

            var search = name.ToUpperInvariant().Trim();

            if (_standardColors.ContainsKey(search))
            {
                return _standardColors[search];
            }

            return StandardColors.White;
        }

        private static void LoadStandardColors()
        {
            _standardColors = new Dictionary<string, Color>();

            var assembly = Assembly.GetExecutingAssembly();

            using (Stream stream = assembly.GetManifestResourceStream("SharpGeo.StandardColors.txt"))
            {
                StreamReader reader = new StreamReader(stream);

                while (true)
                {
                    var line = reader.ReadLine();
                    if (string.IsNullOrWhiteSpace(line))
                    {
                        break;
                    }

                    var values = line.Split(',');
                    _standardColors.Add(values[0].ToUpperInvariant(),
                        new Color(0xff,
                            byte.Parse(values[1], CultureInfo.InvariantCulture),
                            byte.Parse(values[2], CultureInfo.InvariantCulture),
                            byte.Parse(values[3], CultureInfo.InvariantCulture)));
                }
            }
        }
    }
}